package org.asiainfo.file.service;

import org.asiainfo.common.mybatis.stream.core.page.TableDataInfo;
import org.asiainfo.common.mybatis.stream.core.page.PageQuery;

import java.util.Collection;
import java.util.List;

import org.asiainfo.file.domain.vo.AttactmentVo;
import org.asiainfo.file.domain.bo.AttactmentBo;
import org.asiainfo.file.domain.Attactment;
import com.mybatisflex.core.service.IService;
import org.springframework.web.multipart.MultipartFile;

/**
 * 附件文件信息Service接口
 *
 * @author dotor-ww
 */
public interface AttactmentService extends IService<Attactment> {

    /**
     * 通过attactId查询单条数据
     *
     * @param attactId 主键
     * @return 实例对象
     */
    AttactmentVo queryById(Long attactId);

    /**
     * 查询
     *
     * @param attactmentBo 筛选条件
     * @return 查询结果
     */
    List<AttactmentVo> queryList(AttactmentBo attactmentBo);

    /**
     * 分页查询
     *
     * @param attactmentBo 筛选条件
     * @param pageQuery    分页对象
     * @return 查询结果
     */
    TableDataInfo<AttactmentVo> queryPageList(AttactmentBo attactmentBo, PageQuery pageQuery);

    /**
     * 新增数据
     *
     * @param attactmentBo 实例对象
     * @return 实例对象
     */
    Boolean insertByBo(AttactmentBo attactmentBo);

    /**
     * 修改数据
     *
     * @param attactmentBo 实例对象
     */
    Boolean updateByBo(AttactmentBo attactmentBo);

    /**
     * 通过主键删除数据
     *
     * @param attactIds 主键
     */
    Boolean deleteWithValidByIds(Collection<Long> attactIds);

    /**
     * 校验附件业务名称是否唯一
     *
     * @param attactmentBo 附件文件信息
     * @return 校验结果
     */
    Boolean checkAttactmentApplyNameUnique(AttactmentBo attactmentBo);
}
